package StudyCode.summary.myfile;

/**
 * 版权所有 科技与人文(www.tah1986.com)
 */
public class ResourcesPath {
	public static void main(String[] argv) throws Exception {
		String path = "tah1986.com";
		System.out.println(getPathToUse(path));
	}

	private static String getPathToUse(String path) {
		String pathToUse;
		if (path.startsWith("/")) {
			pathToUse = path;
		} else {
			pathToUse = System.getProperty("user.dir") + "/" + path;
		}
		return pathToUse;
	}
}
